<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>JS-基础语法</title>
</head>
<body>
  

  <script>
    //1. 声明变量
    // let a = 10;
    // a = "Hello";
     a = true;
    alert (a);
    // alert(a); //弹出框

    //2. 声明常量
    const PI = 3.14;
    PI = 5.0;

    console.log(PI); //输出到控制台
    // document.write(PI); //输出到body区域(不常用)
  </script>
</body>
</html>